*Table A.12 self reported feedback on the effects of protocol***
cd ""

use "master_data_adults_child_s13456_shared.dta", clear 

drop meal_control snack_control
gen meal_control=1 if treatment==2
replace meal_control=0 if treatment==1
tab meal_control

gen snack_control=1 if treatment==3
replace snack_control=0 if treatment==1
tab snack_control

drop if type_id=="X" // **Dropping newborns born during the three years of study
drop if id=="3885553B" //**error in the id number and empty data
drop if id=="3885553G" //**error in the id number and empty data
replace treatment=2 if id=="38855553B" //**retrieving the correct treatment for this id
replace treatment=2 if id=="38855553G" //**retrieving the correct treatment for this id
drop if id=="101aa22c" //**this id does not exist
drop if id=="27655663" //**outlier on many measurements
 
****************************************
rename tried_new_foods_never_tried_befo tried_new_foods_never_tried_bef
rename have_liked_ingredient_didnot_bef have_liked_ingredient_didnot_be
rename iwassurprisedathowmuchiusedtosna iwassurprisedathowmuch
rename generallyfeltiatelessfoodoverall generallyfelt
 
//recoding
lab define agree ///
	1 "Strongly disagree"  ///	
	2 "Disagree" ///	
	3 "Neitheragree nor disagree" ///
	4 "Agree" ///
	5 "Strongly agree"  , replace
	
lab val tried_new_foods_never_tried_bef cooking_time_consuming child_tried_new_never_tried have_liked_ingredient_didnot_be found_eating_more_meal_times iwassurprisedathowmuch feltlesshungrybetweenmeals generallyfelt agree
 
 //Strongly disagree (1) and disagre (2) are added up. Same for agree (4) and strongly agree(5) 
foreach v of var tried_new_foods_never_tried_bef cooking_time_consuming child_tried_new_never_tried have_liked_ingredient_didnot_be found_eating_more_meal_times iwassurprisedathowmuch feltlesshungrybetweenmeals generallyfelt {
/*/Strongly disagree (1) and disagre (2)*/
 gen `v'2=1 if `v'==1 | `v='==2
 /*strongly agree (4) and agree (5)*/
 replace `v'2=3 if `v'==4 | `v'==5
 replace `v'2=2 if `v'==3
 }
  
*A. MEAL, n=122. Answered by adults//
tab tried_new_foods_never_tried_bef2 if session==3 & treatment==2 & child==0
tab cooking_time_consuming2 if session==3 & treatment==2 & child==0 
tab child_tried_new_never_tried2 if session==3 & treatment==2 & child==0
tab have_liked_ingredient_didnot_be2 if session==3 & treatment==2 & child==0
 
*B. SNACK, n=79. Answered by adults//
tab found_eating_more_meal_times2 if session==3 & treatment==3 & child==0
tab iwassurprisedathowmuch2 if session==3 & treatment==3 & child==0
tab feltlesshungrybetweenmeals2 if session==3 & treatment==3 & child==0
tab generallyfelt2 if session==3 & treatment==3 & child==0 